<?php
$installer = $this;
$installer->startSetup();
$sql=<<<SQLTEXT
CREATE TABLE `md_sliders` (
  `slid` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Primary key for identify a slideshow.',
  `title` longtext NOT NULL COMMENT 'The name of slideshow.',
  `description` varchar(1000) DEFAULT NULL COMMENT 'The description about slideshow is created.',
  `machine_name` varchar(255) NOT NULL COMMENT 'The machine name of slideshow. The uniquied values.',
  `settings` longtext NOT NULL COMMENT 'The common settings for slideshow.',
  PRIMARY KEY (`slid`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='Slideshows table'
;
    
CREATE TABLE `md_slides` (
  `sid` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Primary key for identify a slide.',
  `slid` int(10) unsigned NOT NULL COMMENT 'Slideshow id contain this slide.',
  `position` int(10) unsigned NOT NULL COMMENT 'Order of slide in slideshow.',
  `settings` longtext NOT NULL COMMENT 'Settings for tab',
  `layers` longtext NOT NULL COMMENT 'Items in this slide',
  PRIMARY KEY (`sid`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8 COMMENT='Slides table';

INSERT INTO `md_sliders` (`slid`, `title`, `description`, `machine_name`, `settings`) VALUES
(1, 'Home slideshow', '', 'md_slider_516140632d62c', 'a:24:{s:10:"full_width";i:0;s:5:"width";s:3:"960";s:6:"height";s:3:"420";s:11:"touch_swipe";i:1;s:10:"responsive";i:1;s:10:"loadingbar";s:3:"bar";s:12:"bar_position";s:6:"bottom";s:21:"show_next_prev_button";i:1;s:9:"auto_play";i:1;s:11:"show_bullet";i:1;s:15:"bullet_position";s:1:"5";s:14:"show_thumbnail";i:1;s:18:"thumbnail_position";s:1:"1";s:12:"border_style";s:1:"0";s:16:"dropshadow_style";s:1:"0";s:9:"animation";s:4:"fade";s:5:"delay";s:4:"8000";s:9:"transtime";s:3:"800";s:11:"thumb_width";s:3:"100";s:12:"thumb_height";s:2:"75";s:18:"create_bg_imgstyle";i:0;s:10:"dmf_google";s:0:"";s:15:"enable_font_css";i:0;s:11:"color_saved";s:28:"ff9900,CC0000,ffffff,ffffff,";}')
;

INSERT INTO `md_slides` (`sid`, `slid`, `position`, `settings`, `layers`) VALUES
(1, 1, 0, 'a:3:{s:16:"background_image";i:3;s:13:"timelinewidth";i:80;s:16:"custom_thumbnail";i:-1;}', 'a:2:{i:0;a:26:{s:5:"width";i:100;s:6:"height";i:50;s:4:"left";i:73;s:3:"top";i:58;s:9:"starttime";i:400;s:8:"stoptime";i:4500;s:8:"startani";s:8:"bounceIn";s:7:"stopani";s:7:"fadeOut";s:5:"style";s:18:"text-black-shadow2";s:6:"zindex";s:3:"999";s:4:"type";s:4:"text";s:5:"title";s:20:"Giá sách \n400.000k";s:15:"backgroundcolor";s:6:"ff9900";s:21:"backgroundtransparent";i:20;s:11:"borderstyle";s:5:"solid";s:19:"bordertopleftradius";i:5;s:20:"bordertoprightradius";i:5;s:23:"borderbottomrightradius";i:5;s:22:"borderbottomleftradius";i:5;s:10:"paddingtop";i:5;s:12:"paddingright";i:5;s:13:"paddingbottom";i:5;s:11:"paddingleft";i:5;s:8:"fontsize";i:18;s:10:"fontfamily";s:7:"Georgia";s:5:"color";s:6:"ffffff";}i:1;a:26:{s:5:"width";i:123;s:6:"height";i:50;s:4:"left";i:314;s:3:"top";i:145;s:9:"starttime";i:1200;s:8:"stoptime";i:5800;s:8:"startani";s:13:"bounceInRight";s:7:"stopani";s:9:"rotateOut";s:5:"style";s:17:"text-black-shadow";s:6:"zindex";s:4:"1000";s:4:"type";s:4:"text";s:5:"title";s:26:"Chậu cây cảnh\n80.000k";s:15:"backgroundcolor";s:6:"ff9900";s:21:"backgroundtransparent";i:20;s:11:"borderstyle";s:5:"solid";s:19:"bordertopleftradius";i:5;s:20:"bordertoprightradius";i:5;s:23:"borderbottomrightradius";i:5;s:22:"borderbottomleftradius";i:5;s:10:"paddingtop";i:5;s:12:"paddingright";i:5;s:13:"paddingbottom";i:5;s:11:"paddingleft";i:5;s:8:"fontsize";i:18;s:10:"fontfamily";s:7:"Georgia";s:5:"color";s:6:"ffffff";}}'),
(2, 1, 1, 'a:3:{s:16:"background_image";i:4;s:13:"timelinewidth";i:90;s:16:"custom_thumbnail";i:-1;}', 'a:1:{i:0;a:27:{s:5:"width";i:100;s:6:"height";i:50;s:4:"left";i:396;s:3:"top";i:153;s:9:"starttime";i:0;s:8:"stoptime";i:5300;s:8:"startani";s:12:"lightSpeedIn";s:7:"stopani";s:7:"rollOut";s:7:"opacity";s:3:"100";s:5:"style";s:17:"text-black-shadow";s:6:"zindex";s:4:"1000";s:4:"type";s:4:"text";s:5:"title";s:19:"đèn bàn\n300.000k";s:15:"backgroundcolor";s:6:"ff9900";s:21:"backgroundtransparent";i:20;s:11:"borderstyle";s:5:"solid";s:19:"bordertopleftradius";i:5;s:20:"bordertoprightradius";i:5;s:23:"borderbottomrightradius";i:5;s:22:"borderbottomleftradius";i:5;s:10:"paddingtop";s:1:"5";s:12:"paddingright";s:2:"15";s:13:"paddingbottom";i:5;s:11:"paddingleft";s:2:"15";s:8:"fontsize";i:18;s:10:"fontfamily";s:0:"";s:5:"color";s:6:"ffffff";}}');
SQLTEXT;

$installer->run($sql);
//demo 
//Mage::getModel('core/url_rewrite')->setId(null);
//demo 
$installer->endSetup();
	 